﻿<%@ Page Title="" Language="C#" MasterPageFile="~/UserControl/MasterPage.Master"
    AutoEventWireup="true" CodeBehind="ThongTinCaNhan.aspx.cs" Inherits="TMDT_Nhom1A.Customer.ThongTinCaNhan" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="tk" %>
<%@ Register Src="../UserControl/GioHang.ascx" TagName="GioHang" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder2" runat="server">
    <uc1:GioHang ID="GioHang1" runat="server" />
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <%--<script type="text/javascript">
        $(document).ready(function() {
        $(".btCancelPassword").bind("click", function() {
                alert("sdfsdf");
                $("#rvPasswordOld").attr("Visible", "false");
                $("#rvPasswordNew").attr("Visible", "false");
                $("#rvConfirmPasswordNew").attr("Visible", "false");
                $("#CompareValidatorPass").attr("Visible", "false");
            });
        });
    </script>--%>
    <div class="module_round_box_inner">
        <div class="module_round_box_inner2">
            <div class="s5_mod_h3_1">
                <div class="s5_mod_h3_2">
                    <h3 class="s5_mod_h3">
                        <span class="s5_h3_first">Thông tin cá nhân</span>
                    </h3>
                </div>
            </div>
            <tk:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
            </tk:ToolkitScriptManager>
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
                    <asp:UpdateProgress ID="UpdateProgress1" runat="server">
                        <ProgressTemplate>
                            Đang lấy dữ liệu từ server...
                            <img src="../images/ajax-loader.gif" />&nbsp;&nbsp;
                        </ProgressTemplate>
                    </asp:UpdateProgress>
                    <br />
                    <asp:DataList ID="dlInformationCustomer" runat="server" Width="100%" OnItemCommand="dlInformationCustomer_ItemCommand">
                        <ItemTemplate>
                            <div class="label_register">
                                <asp:Label ID="Label26" runat="server"> Tên công ty :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label1" CssClass="lb_2" Font-Bold="true" Text='<%# Eval("NameCompany") %>'
                                    runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label23" runat="server"> Địa chỉ công ty :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label3" Font-Bold="true" Text='<%# Eval("AddressCompany") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label18" runat="server"> Mã số thuế :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label5" Font-Bold="true" Text='<%# Eval("TaxCode") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label4" runat="server"> Tên:</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label6" Font-Bold="true" Text='<%# Eval("NamePresentation") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label7" runat="server"> Email:</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label8" Font-Bold="true" Text='<%# Eval("Email") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label9" runat="server"> Điện Thoại :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label12" Font-Bold="true" Text='<%# Eval("Phone") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label10" runat="server">Di động :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label13" Font-Bold="true" Text='<%# Eval("Mobile") %>' runat="server"></asp:Label>
                            </div>
                            <div class="label_register">
                                <asp:Label ID="Label11" runat="server">Vai trò :</asp:Label>
                            </div>
                            <div class="textbox_register" style="padding-top: 5px;">
                                <asp:Label ID="Label14" Font-Bold="true" Text='<%# Eval("Role") %>' runat="server"></asp:Label>
                            </div>
                            </div>
                            <div style="margin-left: 500px">
                                <asp:ImageButton ID="Edit" ToolTip="Chỉnh sửa" CommandName="btEditInfor" ImageUrl="~/images/page-edit-icon.png"
                                    runat="server" />
                            </div>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <div id="Div1" runat="server" style="padding-top: 30px; padding-bottom: 30px">
                                <div class="label_register">
                                    <asp:Label ID="Label26" runat="server"> Tên công ty :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="tbnamecompany" Width="200px" CssClass="tb_2" Text='<%# Eval("NameCompany") %>'
                                        runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator15" runat="server" ControlToValidate="tbnamecompany"
                                        ErrorMessage="*"></asp:RequiredFieldValidator>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label23" runat="server"> Địa chỉ công ty :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="tbaddresscompany" Width="200px" CssClass="tb_2" Text='<%# Eval("AddressCompany") %>'
                                        runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="tbaddresscompany"
                                        ErrorMessage="*"></asp:RequiredFieldValidator>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label18" runat="server"> Mã số thuế :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="tbnumebertax" Text='<%# Eval("TaxCode") %>' Width="200px" CssClass="tb_2"
                                        runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" ControlToValidate="tbnumebertax"
                                        ErrorMessage="*"></asp:RequiredFieldValidator>
                                    <tk:FilteredTextBoxExtender ID="FilteredTextBoxExtender1" TargetControlID="tbnumebertax"
                                        FilterType="Numbers" runat="server">
                                    </tk:FilteredTextBoxExtender>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label2" runat="server"> Password:</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:Panel ID="Panel1" Visible="false" runat="server" Style="border-color: #d1c7ac;
                                        border-width: 1px; border-style: double; padding: 5px; margin-bottom: 7px">
                                        <asp:TextBox ID="Label15" runat="server" Text='<%# Eval("Password") %>' Visible="false"></asp:TextBox>
                                        Nhập password cũ :
                                        <asp:TextBox ID="txtPasswordOld" CssClass="tb_2" Width="200px" runat="server" TextMode="Password"></asp:TextBox>
                                        <br />
                                        Nhập password mới :
                                        <asp:TextBox ID="txtPasswordNew" CssClass="tb_2" Width="200px" runat="server" TextMode="Password"></asp:TextBox>
                                        <%--<asp:RequiredFieldValidator ID="rvPasswordNew" Visible="false" ControlToValidate="txtPasswordNew"
                                            runat="server" ErrorMessage="*"></asp:RequiredFieldValidator>--%>
                                        <br />
                                        Xác nhận password mới :
                                        <asp:TextBox ID="txtConfirmPasswordNew" CssClass="tb_2" Width="200px" runat="server"
                                            TextMode="Password"></asp:TextBox>
                                        <%--<asp:RequiredFieldValidator ID="rvConfirmPasswordNew" Visible="false" runat="server"
                                            ControlToValidate="txtConfirmPasswordNew" ErrorMessage="*"></asp:RequiredFieldValidator>--%>
                                        <br />
                                        <asp:CompareValidator ID="CompareValidatorPass" runat="server" ControlToCompare="txtPasswordNew"
                                            ControlToValidate="txtConfirmPasswordNew" ErrorMessage="xác nhận mật khẩu không đúng"></asp:CompareValidator>
                                        <br />
                                        <asp:Label Visible="false" Font-Bold="true" ForeColor="Red" ID="lbInfoError" runat="server"></asp:Label>
                                        <br />
                                        <asp:ImageButton ID="btCancelPassword" ToolTip="thoát" Height="20px" Width="20px" CommandName="btCancelPassword"
                                            ImageUrl="~/images/post-delete-icon.png" runat="server" OnClientClick="if(!confirm('Không muốn cập nhật password?')) return false;" />
                                    </asp:Panel>
                                    <asp:ImageButton ID="btEditPassword" ToolTip="chỉnh sửa password" Style="margin-bottom: 7px" Height="20px" Width="20px"
                                        CommandName="btEditPassword" ImageUrl="~/images/page-edit-icon.png" runat="server" />
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label4" runat="server"> Tên:</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="txtTen" Width="200px" CssClass="tb_2" Text='<%# Eval("NamePresentation") %>'
                                        runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" ControlToValidate="txtTen"
                                        ErrorMessage="*"></asp:RequiredFieldValidator>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label7" runat="server"> Email:</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="txtEmail" Text='<%# Eval("Email") %>' Width="200px" CssClass="tb_2"
                                        runat="server"></asp:TextBox>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" ControlToValidate="txtEmail"
                                        ErrorMessage="*"></asp:RequiredFieldValidator>
                                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" ControlToValidate="txtEmail"
                                        ErrorMessage="Emai không hợp lệ" ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"></asp:RegularExpressionValidator>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label9" runat="server"> Điện Thoại :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="txtdienthoai" Width="200px" Text='<%# Eval("Phone") %>' CssClass="tb_2"
                                        runat="server"></asp:TextBox>
                                    <asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server" ControlToValidate="txtdienthoai"
                                        ErrorMessage="Vui lòng nhập số" ValidationExpression="^\d+$"></asp:RegularExpressionValidator>
                                    <tk:FilteredTextBoxExtender ID="FilteredTextBoxExtender2" FilterType="Numbers" TargetControlID="txtdienthoai"
                                        runat="server">
                                    </tk:FilteredTextBoxExtender>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label10" runat="server">Di động :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="txtdidong" Text='<%# Eval("Mobile") %>' Width="200px" CssClass="tb_2"
                                        runat="server"></asp:TextBox>
                                    <asp:RegularExpressionValidator ID="RegularExpressionValidator3" runat="server" ControlToValidate="txtdidong"
                                        ErrorMessage="Vui lòng nhập số" ValidationExpression="^\d+$"></asp:RegularExpressionValidator>
                                    <tk:FilteredTextBoxExtender ID="FilteredTextBoxExtender3" FilterType="Numbers" TargetControlID="txtdidong"
                                        runat="server">
                                    </tk:FilteredTextBoxExtender>
                                </div>
                                <div class="label_register">
                                    <asp:Label ID="Label11" runat="server">Vai trò :</asp:Label>
                                </div>
                                <div class="textbox_register">
                                    <asp:TextBox ID="tbrole" Text='<%# Eval("Role") %>' Width="200px" CssClass="tb_2"
                                        runat="server"></asp:TextBox>
                                </div>
                            </div>
                            <div style="margin-left: 500px">
                                <asp:ImageButton ID="btUpdateInfor" ToolTip="cập nhật" CommandName="btUpdateInfor" ImageUrl="~/images/post-accept-icon.png"
                                    runat="server" OnClientClick="if(!confirm('Bạn có muốn cập nhật thông tin này không ?')) return false;" />
                                <asp:ImageButton ID="btCancelInfor" ToolTip="thoát" CommandName="btCancelInfor" ImageUrl="~/images/post-delete-icon.png"
                                    runat="server" OnClientClick="if(!confirm('Không muốn cập nhật sản phẩm thông tin này ?')) return false;" />
                            </div>
                        </EditItemTemplate>
                    </asp:DataList>
                </ContentTemplate>
            </asp:UpdatePanel>
        </div>
    </div>
</asp:Content>
